<template>
  <div>
    <div class="boss">
      <!-- nav 条 -->
      <head-page
        title="人才仅需查询"
        style="border-bottom: 2px solid #dad9df"
        id="backstyle"
      >
      </head-page>
      <Banner :id="2" class="bannerId"></Banner>
      <div class="text title-center l-h">
        {{ title }}
      </div>
      <!-- 版心区域 -->
      <div class="war">
        <div class="area-center center bold-size">
          <!-- 人才库区域 -->
          <!-- 底部区域 -->
          <div class="bottom">
            <div
              class="small"
              v-for="(item, index) in list"
              :key="index"
              @click="personku(item.provincial, title)"
            >
              {{ item.provincial }}
            </div>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>
  
  <script>
import Banner from "@/components/Home/BannerView.vue";
import { Notice, personType } from "@/api/index";
export default {
  data() {
    return {
      num: [
        { text: "用人单位浏览须知" },
        { text: "各省人才库储备" },
        { text: "人才储备免费登记" },
      ],
      list: [],
      typeList: [],
      tex: "",
      title: this.$route.query.title,
    };
  },
  components: {
    Banner,
  },
  mounted() {
    //获取各省
    Notice().then((res) => {
      //  console.log(res.data);
      this.list = res.data;
    });
    personType().then((res) => {
      let data = res.data;
      if (data.code == 200) {
        this.typeList = data.data;
      }
    });
  },
  methods: {
    person(id) {
      if (id == "11") {
        this.$router.push("/personsix");
      } else if (id == "12" || id == "13") {
        this.$router.push({
          path: "/persontwo/personthree",
          query: {
            id: id,
          },
        });
      } else {
        this.$router.push("/personmin");
      }
    },
    //跳转人才库
    personku(id, title) {
      this.$router.push({ path: "/person", query: { id, title } });
      // this.tex=id
      this.$store.commit("NUM_LIST_ADD_DATA", { inputval: id });
    },
  },
};
</script>
  
  <style scoped>
/* 整体区域 */
.boss {
  width: 100%;
  height: calc(100vh - 0.55rem);
  /* background-color: #f0eff5; */
}
.text {
  width: 100%;
  text-align: center;
  
}
/* 版心区域 */
.center {
  margin: 0 1%;
}

/* 用人单位区域 */
.umit {
  width: 100%;
  min-height: 0.4rem;
  background-color: white;
}
.xiao {
  width: 100%;
  margin-top: 0.05rem;
  display: flex;
}
/* 左边区域 */
.xiao .left {
  width: 5%;
  height: 100%;
  margin-left: 0.1rem;
}
.xiao .left img {
  width: 0.17rem;
  height: 0.3rem;
}
/* 中间区域 */
.zhong {
  height: 100%;
  line-height: 0.3rem;
  padding-left: 0.05rem;
  display: inline-block;
}

/* 底部区域 */
.bottom {
  width: 100%;
  margin-top: 0.05rem;
  display: flex;
  flex-wrap: wrap;
  background-color: white;
}
.small {
  min-width: 0.5rem;
  height: 0.3rem;
  flex-shrink: 0;
  text-align: center;
  line-height: 0.3rem;
  margin: 4px;
}
</style>